package com.qiang.demo01.damain;

import java.util.ArrayList;
import java.util.Date;
import java.util.Objects;

public class Student{
    private String id;

    private String name;

    private String sex;

    private int age;

    private Date birthday;

    private int group;//组编号
    private String Phonenumber;

    private ArrayList<String> wechat;

    public Student() {
    }

    public Student(String id, String name, String sex, int age, Date birthday, int group, String phonenumber, ArrayList<String> wechat) {
        this.id = id;
        this.name = name;
        this.sex = sex;
        this.age = age;
        this.birthday = birthday;
        this.group = group;
        Phonenumber = phonenumber;
        this.wechat = wechat;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public int getGroup() {
        return group;
    }

    public void setGroup(int group) {
        this.group = group;
    }

    public String getPhonenumber() {
        return Phonenumber;
    }

    public void setPhonenumber(String phonenumber) {
        Phonenumber = phonenumber;
    }

    public ArrayList<String> getWechat() {
        return wechat;
    }

    public void setWechat(ArrayList<String> wechat) {
        this.wechat = wechat;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Student student = (Student) o;
        return age == student.age &&
                group == student.group &&
                Objects.equals(id, student.id) &&
                Objects.equals(name, student.name) &&
                Objects.equals(sex, student.sex) &&
                Objects.equals(birthday, student.birthday) &&
                Objects.equals(Phonenumber, student.Phonenumber) &&
                Objects.equals(wechat, student.wechat);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id, name, sex, age, birthday, group, Phonenumber, wechat);
    }

    @Override
    public String toString() {
        return "Student{" +
                "id='" + id + '\'' +
                ", name='" + name + '\'' +
                ", sex='" + sex + '\'' +
                ", age=" + age +
                ", birthday=" + birthday +
                ", group=" + group +
                ", Phonenumber='" + Phonenumber + '\'' +
                ", wechat=" + wechat +
                '}';
    }
}
